<!DOCTYPE html>
{% load static %}
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>{% block title %}CoolYunTest·自动化平台{% endblock %}</title>

    <!-- ico 图标 -->
    <link rel="icon" type="image/svg" href="{% static 'images/cool-icon.svg' %}">
    <!-- Bootstrap 核心CSS -->
    <link href="{% static 'vendor/bootstrap-5.2.3/css/bootstrap.min.css' %}" rel="stylesheet">
    <!-- Font Awesome -->
    <link href="{% static 'vendor/fontawesome-free-6.7.2/css/all.min.css' %}" rel="stylesheet">

    <!-- 自定义CSS -->
    <link href="{% static 'css/global.css' %}" rel="stylesheet">
    <link href="{% static 'css/includes/navbar.css' %} " rel="stylesheet">
    <link href="{% static 'css/includes/footer.css' %}" rel="stylesheet">

    <!-- 页面级扩展CSS -->
    {% block extra_css %}{% endblock %}

</head>
<body>


<!-- 导航栏 -->
<nav class="main-navbar">
    {% include 'includes/navbar.html' %}
</nav>

<!-- 动态内容区 -->
<main class="content-container">
    {% block content %}{% endblock %}
</main>

<!-- 页脚 -->
<footer class="main-footer">
    {% include "includes/footer.html" %}
</footer>

<!-- JavaScript 区块 -->
{% block javascript %}
    <!-- 第三方插件 -->
    <script src="{% static 'vendor/jquery-3.6.0/jquery.min.js' %}"></script>
    <script src="{% static 'vendor/bootstrap-5.2.3/js/bootstrap.bundle.min.js' %}"></script>
    <script src="{% static 'js/components/navbar.js' %}"></script>
    <!-- 全局初始化 -->
    <script>
        // 通用 CSRF 配置
        $(document).ajaxSend(function (event, xhr, settings) {
            xhr.setRequestHeader("X-CSRFToken", "{{ csrf_token }}");
        });
    </script>
{% endblock %}

{# 页面专属脚本扩展点 #}
{% block extra_scripts %}{% endblock %}
</body>

</html>
